Ray,
Brad recently added that in and Kevin reported it working. Search for:
public void SetMcodeAction(int index, MCODE_TYPE type, double val1, double val2, double val3, double val4, double val5, string name)
Regards
TK
Group: DynoMotion |
Message: 3327 |
From: Brad Murry |
Date: 1/22/2012 |
Subject: Re: How Do M-Codes Get Hooked Into Interpreter? |
Look back a couple weeks here in the forum, I had a discussion on how to use it with Kevin. You will have to update your KMotion_dotNet and Interop projects and rebuild the DLL’s if you only have the base 428 install. -Brad Murry From: DynoMotion@yahoogroups.com [mailto:DynoMotion@yahoogroups.com] On Behalf Of himykabibble Sent: Sunday, January 22, 2012 4:39 PM To: DynoMotion@yahoogroups.com Subject: [DynoMotion] How Do M-Codes Get Hooked Into Interpreter? Tom/Brad
How do M-codes get hooked into the interpreter? I don't see anything in the APIs that would support that, so I'm sure I must be looking in the wrong place.
Regards, Ray L.
|
|
Group: DynoMotion |
Message: 3330 |
From: himykabibble |
Date: 1/22/2012 |
Subject: Re: How Do M-Codes Get Hooked Into Interpreter? |
Tom,
I don't see it in KM_Controller, or KM_Controller.Interpreter.... Is there somewhere else I should be looking? Do I have out of date code?
Regards,
Ray L.
--- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@...> wrote:
>
> Ray,
> Â
> Brad recently added that in and Kevin reported it working. Search for:
> Â publicvoidSetMcodeAction(intindex, MCODE_TYPE type, doubleval1, doubleval2, doubleval3, doubleval4, doubleval5, stringname)
> Â
> Regards
> TK
> Â
> Â
> From: himykabibble <jagboy@...>
> To: DynoMotion@yahoogroups.com
> Sent: Sunday, January 22, 2012 3:38 PM
> Subject: [DynoMotion] How Do M-Codes Get Hooked Into Interpreter?
>
>
> Â
> Tom/Brad
>
> How do M-codes get hooked into the interpreter? I don't see anything in the APIs that would support that, so I'm sure I must be looking in the wrong place.
>
> Regards,
> Ray L.
>
|
|
Group: DynoMotion |
Message: 3333 |
From: Tom Kerekes |
Date: 1/22/2012 |
Subject: Re: How Do M-Codes Get Hooked Into Interpreter? |
Yes you have to get the latest from Brad. I think it is dated 1-10-12
TK
Group: DynoMotion |
Message: 3335 |
From: himykabibble |
Date: 1/22/2012 |
Subject: Re: How Do M-Codes Get Hooked Into Interpreter? |
Brad,
Update them from where? I see an MM update about two weeks ago. Is that it? Is there some fixed location I can go to for updates? It's WAY too easy to miss an announcement here.
Regards,
Ray L.
--- In DynoMotion@yahoogroups.com, Brad Murry <bradodarb@...> wrote:
>
> Look back a couple weeks here in the forum, I had a discussion on how to use
> it with Kevin.
>
>
>
> You will have to update your KMotion_dotNet and Interop projects and rebuild
> the DLL's if you only have the base 428 install.
>
>
>
> -Brad Murry
>
>
>
> From: DynoMotion@yahoogroups.com [mailto:DynoMotion@yahoogroups.com] On
> Behalf Of himykabibble
> Sent: Sunday, January 22, 2012 4:39 PM
> To: DynoMotion@yahoogroups.com
> Subject: [DynoMotion] How Do M-Codes Get Hooked Into Interpreter?
>
>
>
>
>
> Tom/Brad
>
> How do M-codes get hooked into the interpreter? I don't see anything in the
> APIs that would support that, so I'm sure I must be looking in the wrong
> place.
>
> Regards,
> Ray L.
>
|
|
Group: DynoMotion |
Message: 3336 |
From: himykabibble |
Date: 1/22/2012 |
Subject: Re: How Do M-Codes Get Hooked Into Interpreter? |
Brad,
I've downloaded the compiled DLLs you posted on 1/12, but I'm getting an exception in this block:
private void Set_G_USER_MCODE_CALLBACK()
{
try
{
InterpreterUserMCodeCallbackRequestedHandler = new KM_GCodeInterpreterUserMcodeCallbackHandler(OnInterpreterUserMcodeCallbackRequested);
KM_dotnet_Interop_GCodeInterpreter_Set_G_USER_MCODE_CALLBACK(_InstanceHandle, InterpreterUserMCodeCallbackRequestedHandler);
}
It's the Interpreter call that's throwing it.
Regards,
Ray L.
--- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@...> wrote:
>
> Brad,
>
> Update them from where? I see an MM update about two weeks ago. Is that it? Is there some fixed location I can go to for updates? It's WAY too easy to miss an announcement here.
>
> Regards,
> Ray L.
>
> --- In DynoMotion@yahoogroups.com, Brad Murry <bradodarb@> wrote:
> >
> > Look back a couple weeks here in the forum, I had a discussion on how to use
> > it with Kevin.
> >
> >
> >
> > You will have to update your KMotion_dotNet and Interop projects and rebuild
> > the DLL's if you only have the base 428 install.
> >
> >
> >
> > -Brad Murry
> >
> >
> >
> > From: DynoMotion@yahoogroups.com [mailto:DynoMotion@yahoogroups.com] On
> > Behalf Of himykabibble
> > Sent: Sunday, January 22, 2012 4:39 PM
> > To: DynoMotion@yahoogroups.com
> > Subject: [DynoMotion] How Do M-Codes Get Hooked Into Interpreter?
> >
> >
> >
> >
> >
> > Tom/Brad
> >
> > How do M-codes get hooked into the interpreter? I don't see anything in the
> > APIs that would support that, so I'm sure I must be looking in the wrong
> > place.
> >
> > Regards,
> > Ray L.
> >
>
|
|
Group: DynoMotion |
Message: 3337 |
From: Brad Murry |
Date: 1/22/2012 |
Subject: Re: How Do M-Codes Get Hooked Into Interpreter? |
Ray can you be more specific ? -Brad Murry From: DynoMotion@yahoogroups.com [mailto:DynoMotion@yahoogroups.com] On Behalf Of himykabibble Sent: Sunday, January 22, 2012 6:23 PM To: DynoMotion@yahoogroups.com Subject: [DynoMotion] Re: How Do M-Codes Get Hooked Into Interpreter? Brad,
I've downloaded the compiled DLLs you posted on 1/12, but I'm getting an exception in this block:
private void Set_G_USER_MCODE_CALLBACK() { try { InterpreterUserMCodeCallbackRequestedHandler = new KM_GCodeInterpreterUserMcodeCallbackHandler(OnInterpreterUserMcodeCallbackRequested); KM_dotnet_Interop_GCodeInterpreter_Set_G_USER_MCODE_CALLBACK(_InstanceHandle, InterpreterUserMCodeCallbackRequestedHandler); }
It's the Interpreter call that's throwing it.
Regards, Ray L.
--- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@...> wrote: > > Brad, > > Update them from where? I see an MM update about two weeks ago. Is that it? Is there some fixed location I can go to for updates? It's WAY too easy to miss an announcement here. > > Regards, > Ray L. > > --- In DynoMotion@yahoogroups.com, Brad Murry <bradodarb@> wrote: > > > > Look back a couple weeks here in the forum, I had a discussion on how to use > > it with Kevin. > > > > > > > > You will have to update your KMotion_dotNet and Interop projects and rebuild > > the DLL's if you only have the base 428 install. > > > > > > > > -Brad Murry > > > > > > > > From: DynoMotion@yahoogroups.com [mailto:DynoMotion@yahoogroups.com] On > > Behalf Of himykabibble > > Sent: Sunday, January 22, 2012 4:39 PM > > To: DynoMotion@yahoogroups.com > > Subject: [DynoMotion] How Do M-Codes Get Hooked Into Interpreter? > > > > > > > > > > > > Tom/Brad > > > > How do M-codes get hooked into the interpreter? I don't see anything in the > > APIs that would support that, so I'm sure I must be looking in the wrong > > place. > > > > Regards, > > Ray L. > > >
|
|
Group: DynoMotion |
Message: 3338 |
From: himykabibble |
Date: 1/22/2012 |
Subject: Re: How Do M-Codes Get Hooked Into Interpreter? |
The exception originates in this code, in the Set_G_USER_MCODE_CALLBACK() call:
try
{
KM_dotnet_Interop_GCodeInterpreter_New(ref _InstanceHandle);
Set_G_COMPLETE_CALLBACK();
Set_G_STATUS_CALLBACK();
Set_G_USER_CALLBACK();
Set_G_USER_MCODE_CALLBACK();
SetStraightTraverseCallback();
SetStraightFeedCallback();
SetArcFeedCallback();
}
Regards,
Ray L.
--- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@...> wrote:
>
> Brad,
>
> I've downloaded the compiled DLLs you posted on 1/12, but I'm getting an exception in this block:
>
> private void Set_G_USER_MCODE_CALLBACK()
> {
> try
> {
> InterpreterUserMCodeCallbackRequestedHandler = new KM_GCodeInterpreterUserMcodeCallbackHandler(OnInterpreterUserMcodeCallbackRequested);
> KM_dotnet_Interop_GCodeInterpreter_Set_G_USER_MCODE_CALLBACK(_InstanceHandle, InterpreterUserMCodeCallbackRequestedHandler);
> }
>
> It's the Interpreter call that's throwing it.
>
> Regards,
> Ray L.
>
>
> --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> >
> > Brad,
> >
> > Update them from where? I see an MM update about two weeks ago. Is that it? Is there some fixed location I can go to for updates? It's WAY too easy to miss an announcement here.
> >
> > Regards,
> > Ray L.
> >
> > --- In DynoMotion@yahoogroups.com, Brad Murry <bradodarb@> wrote:
> > >
> > > Look back a couple weeks here in the forum, I had a discussion on how to use
> > > it with Kevin.
> > >
> > >
> > >
> > > You will have to update your KMotion_dotNet and Interop projects and rebuild
> > > the DLL's if you only have the base 428 install.
> > >
> > >
> > >
> > > -Brad Murry
> > >
> > >
> > >
> > > From: DynoMotion@yahoogroups.com [mailto:DynoMotion@yahoogroups.com] On
> > > Behalf Of himykabibble
> > > Sent: Sunday, January 22, 2012 4:39 PM
> > > To: DynoMotion@yahoogroups.com
> > > Subject: [DynoMotion] How Do M-Codes Get Hooked Into Interpreter?
> > >
> > >
> > >
> > >
> > >
> > > Tom/Brad
> > >
> > > How do M-codes get hooked into the interpreter? I don't see anything in the
> > > APIs that would support that, so I'm sure I must be looking in the wrong
> > > place.
> > >
> > > Regards,
> > > Ray L.
> > >
> >
>
|
|
Group: DynoMotion |
Message: 3339 |
From: himykabibble |
Date: 1/22/2012 |
Subject: Re: How Do M-Codes Get Hooked Into Interpreter? |
Brad,
There are clearly many things I am not understanding about how .NET locates things.... I have a reference in my project to the dotNet DLL in the KMotion/Release directory. It will not allow me to add a reference to the Interop DLL. In this case, it copied the dotNet DLL to the Debug directory, but did not copy the Interop DLL. I manually copied the Interop DLL, and it now works. What am I doing wrong? Why can't I set a reference to the Interop DLL, and how do I get it to copy it anyway?
Regards,
Ray L.
--- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@...> wrote:
>
> The exception originates in this code, in the Set_G_USER_MCODE_CALLBACK() call:
>
> try
> {
> KM_dotnet_Interop_GCodeInterpreter_New(ref _InstanceHandle);
> Set_G_COMPLETE_CALLBACK();
> Set_G_STATUS_CALLBACK();
> Set_G_USER_CALLBACK();
> Set_G_USER_MCODE_CALLBACK();
> SetStraightTraverseCallback();
> SetStraightFeedCallback();
> SetArcFeedCallback();
> }
>
> Regards,
> Ray L.
>
>
> --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> >
> > Brad,
> >
> > I've downloaded the compiled DLLs you posted on 1/12, but I'm getting an exception in this block:
> >
> > private void Set_G_USER_MCODE_CALLBACK()
> > {
> > try
> > {
> > InterpreterUserMCodeCallbackRequestedHandler = new KM_GCodeInterpreterUserMcodeCallbackHandler(OnInterpreterUserMcodeCallbackRequested);
> > KM_dotnet_Interop_GCodeInterpreter_Set_G_USER_MCODE_CALLBACK(_InstanceHandle, InterpreterUserMCodeCallbackRequestedHandler);
> > }
> >
> > It's the Interpreter call that's throwing it.
> >
> > Regards,
> > Ray L.
> >
> >
> > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > >
> > > Brad,
> > >
> > > Update them from where? I see an MM update about two weeks ago. Is that it? Is there some fixed location I can go to for updates? It's WAY too easy to miss an announcement here.
> > >
> > > Regards,
> > > Ray L.
> > >
> > > --- In DynoMotion@yahoogroups.com, Brad Murry <bradodarb@> wrote:
> > > >
> > > > Look back a couple weeks here in the forum, I had a discussion on how to use
> > > > it with Kevin.
> > > >
> > > >
> > > >
> > > > You will have to update your KMotion_dotNet and Interop projects and rebuild
> > > > the DLL's if you only have the base 428 install.
> > > >
> > > >
> > > >
> > > > -Brad Murry
> > > >
> > > >
> > > >
> > > > From: DynoMotion@yahoogroups.com [mailto:DynoMotion@yahoogroups.com] On
> > > > Behalf Of himykabibble
> > > > Sent: Sunday, January 22, 2012 4:39 PM
> > > > To: DynoMotion@yahoogroups.com
> > > > Subject: [DynoMotion] How Do M-Codes Get Hooked Into Interpreter?
> > > >
> > > >
> > > >
> > > >
> > > >
> > > > Tom/Brad
> > > >
> > > > How do M-codes get hooked into the interpreter? I don't see anything in the
> > > > APIs that would support that, so I'm sure I must be looking in the wrong
> > > > place.
> > > >
> > > > Regards,
> > > > Ray L.
> > > >
> > >
> >
>
|
|
Group: DynoMotion |
Message: 3340 |
From: Tom Kerekes |
Date: 1/22/2012 |
Subject: Re: How Do M-Codes Get Hooked Into Interpreter? |
Hi Ray,
I recall that Brad added that after the M_CODE_ACTION stuff.
Maybe verify the call is really there and recompile the libs
TK
Group: DynoMotion |
Message: 3341 |
From: himykabibble |
Date: 1/22/2012 |
Subject: Re: How Do M-Codes Get Hooked Into Interpreter? |
We have MCodes! I've got spindle and coolant controls working! Tomorrow AM, I get to try it on the machine!
The axis speeds are waaaaaay slow (rapids are probably no more than about 10% the speed they should be), but positions/counts are correct. I'll double-check my numbers. But it is working!
Regards,
Ray L.
--- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@...> wrote:
>
> Brad,
>
> There are clearly many things I am not understanding about how .NET locates things.... I have a reference in my project to the dotNet DLL in the KMotion/Release directory. It will not allow me to add a reference to the Interop DLL. In this case, it copied the dotNet DLL to the Debug directory, but did not copy the Interop DLL. I manually copied the Interop DLL, and it now works. What am I doing wrong? Why can't I set a reference to the Interop DLL, and how do I get it to copy it anyway?
>
> Regards,
> Ray L.
>
> --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> >
> > The exception originates in this code, in the Set_G_USER_MCODE_CALLBACK() call:
> >
> > try
> > {
> > KM_dotnet_Interop_GCodeInterpreter_New(ref _InstanceHandle);
> > Set_G_COMPLETE_CALLBACK();
> > Set_G_STATUS_CALLBACK();
> > Set_G_USER_CALLBACK();
> > Set_G_USER_MCODE_CALLBACK();
> > SetStraightTraverseCallback();
> > SetStraightFeedCallback();
> > SetArcFeedCallback();
> > }
> >
> > Regards,
> > Ray L.
> >
> >
> > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > >
> > > Brad,
> > >
> > > I've downloaded the compiled DLLs you posted on 1/12, but I'm getting an exception in this block:
> > >
> > > private void Set_G_USER_MCODE_CALLBACK()
> > > {
> > > try
> > > {
> > > InterpreterUserMCodeCallbackRequestedHandler = new KM_GCodeInterpreterUserMcodeCallbackHandler(OnInterpreterUserMcodeCallbackRequested);
> > > KM_dotnet_Interop_GCodeInterpreter_Set_G_USER_MCODE_CALLBACK(_InstanceHandle, InterpreterUserMCodeCallbackRequestedHandler);
> > > }
> > >
> > > It's the Interpreter call that's throwing it.
> > >
> > > Regards,
> > > Ray L.
> > >
> > >
> > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > >
> > > > Brad,
> > > >
> > > > Update them from where? I see an MM update about two weeks ago. Is that it? Is there some fixed location I can go to for updates? It's WAY too easy to miss an announcement here.
> > > >
> > > > Regards,
> > > > Ray L.
> > > >
> > > > --- In DynoMotion@yahoogroups.com, Brad Murry <bradodarb@> wrote:
> > > > >
> > > > > Look back a couple weeks here in the forum, I had a discussion on how to use
> > > > > it with Kevin.
> > > > >
> > > > >
> > > > >
> > > > > You will have to update your KMotion_dotNet and Interop projects and rebuild
> > > > > the DLL's if you only have the base 428 install.
> > > > >
> > > > >
> > > > >
> > > > > -Brad Murry
> > > > >
> > > > >
> > > > >
> > > > > From: DynoMotion@yahoogroups.com [mailto:DynoMotion@yahoogroups.com] On
> > > > > Behalf Of himykabibble
> > > > > Sent: Sunday, January 22, 2012 4:39 PM
> > > > > To: DynoMotion@yahoogroups.com
> > > > > Subject: [DynoMotion] How Do M-Codes Get Hooked Into Interpreter?
> > > > >
> > > > >
> > > > >
> > > > >
> > > > >
> > > > > Tom/Brad
> > > > >
> > > > > How do M-codes get hooked into the interpreter? I don't see anything in the
> > > > > APIs that would support that, so I'm sure I must be looking in the wrong
> > > > > place.
> > > > >
> > > > > Regards,
> > > > > Ray L.
> > > > >
> > > >
> > >
> >
>
|
|
Group: DynoMotion |
Message: 3342 |
From: himykabibble |
Date: 1/22/2012 |
Subject: Re: How Do M-Codes Get Hooked Into Interpreter? |
Where are the MCode arguments defined? It was easy enough to figure out the bit set ones by trial and error, but what about the others? Are they all in the same order as the KMotionCNC GUI?
Regards,
Ray L.
--- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@...> wrote:
>
> We have MCodes! I've got spindle and coolant controls working! Tomorrow AM, I get to try it on the machine!
>
> The axis speeds are waaaaaay slow (rapids are probably no more than about 10% the speed they should be), but positions/counts are correct. I'll double-check my numbers. But it is working!
>
> Regards,
> Ray L.
>
> --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> >
> > Brad,
> >
> > There are clearly many things I am not understanding about how .NET locates things.... I have a reference in my project to the dotNet DLL in the KMotion/Release directory. It will not allow me to add a reference to the Interop DLL. In this case, it copied the dotNet DLL to the Debug directory, but did not copy the Interop DLL. I manually copied the Interop DLL, and it now works. What am I doing wrong? Why can't I set a reference to the Interop DLL, and how do I get it to copy it anyway?
> >
> > Regards,
> > Ray L.
> >
> > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > >
> > > The exception originates in this code, in the Set_G_USER_MCODE_CALLBACK() call:
> > >
> > > try
> > > {
> > > KM_dotnet_Interop_GCodeInterpreter_New(ref _InstanceHandle);
> > > Set_G_COMPLETE_CALLBACK();
> > > Set_G_STATUS_CALLBACK();
> > > Set_G_USER_CALLBACK();
> > > Set_G_USER_MCODE_CALLBACK();
> > > SetStraightTraverseCallback();
> > > SetStraightFeedCallback();
> > > SetArcFeedCallback();
> > > }
> > >
> > > Regards,
> > > Ray L.
> > >
> > >
> > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > >
> > > > Brad,
> > > >
> > > > I've downloaded the compiled DLLs you posted on 1/12, but I'm getting an exception in this block:
> > > >
> > > > private void Set_G_USER_MCODE_CALLBACK()
> > > > {
> > > > try
> > > > {
> > > > InterpreterUserMCodeCallbackRequestedHandler = new KM_GCodeInterpreterUserMcodeCallbackHandler(OnInterpreterUserMcodeCallbackRequested);
> > > > KM_dotnet_Interop_GCodeInterpreter_Set_G_USER_MCODE_CALLBACK(_InstanceHandle, InterpreterUserMCodeCallbackRequestedHandler);
> > > > }
> > > >
> > > > It's the Interpreter call that's throwing it.
> > > >
> > > > Regards,
> > > > Ray L.
> > > >
> > > >
> > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > > >
> > > > > Brad,
> > > > >
> > > > > Update them from where? I see an MM update about two weeks ago. Is that it? Is there some fixed location I can go to for updates? It's WAY too easy to miss an announcement here.
> > > > >
> > > > > Regards,
> > > > > Ray L.
> > > > >
> > > > > --- In DynoMotion@yahoogroups.com, Brad Murry <bradodarb@> wrote:
> > > > > >
> > > > > > Look back a couple weeks here in the forum, I had a discussion on how to use
> > > > > > it with Kevin.
> > > > > >
> > > > > >
> > > > > >
> > > > > > You will have to update your KMotion_dotNet and Interop projects and rebuild
> > > > > > the DLL's if you only have the base 428 install.
> > > > > >
> > > > > >
> > > > > >
> > > > > > -Brad Murry
> > > > > >
> > > > > >
> > > > > >
> > > > > > From: DynoMotion@yahoogroups.com [mailto:DynoMotion@yahoogroups.com] On
> > > > > > Behalf Of himykabibble
> > > > > > Sent: Sunday, January 22, 2012 4:39 PM
> > > > > > To: DynoMotion@yahoogroups.com
> > > > > > Subject: [DynoMotion] How Do M-Codes Get Hooked Into Interpreter?
> > > > > >
> > > > > >
> > > > > >
> > > > > >
> > > > > >
> > > > > > Tom/Brad
> > > > > >
> > > > > > How do M-codes get hooked into the interpreter? I don't see anything in the
> > > > > > APIs that would support that, so I'm sure I must be looking in the wrong
> > > > > > place.
> > > > > >
> > > > > > Regards,
> > > > > > Ray L.
> > > > > >
> > > > >
> > > >
> > >
> >
>
|
|
Group: DynoMotion |
Message: 3343 |
From: himykabibble |
Date: 1/22/2012 |
Subject: Re: How Do M-Codes Get Hooked Into Interpreter? |
Also, how are S-words passed from the interpreter. I currently have DSP code that handles this, but I don't see a method to set the function handler for S words.
Regards,
Ray L.
--- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@...> wrote:
>
> Where are the MCode arguments defined? It was easy enough to figure out the bit set ones by trial and error, but what about the others? Are they all in the same order as the KMotionCNC GUI?
>
> Regards,
> Ray L.
>
> --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> >
> > We have MCodes! I've got spindle and coolant controls working! Tomorrow AM, I get to try it on the machine!
> >
> > The axis speeds are waaaaaay slow (rapids are probably no more than about 10% the speed they should be), but positions/counts are correct. I'll double-check my numbers. But it is working!
> >
> > Regards,
> > Ray L.
> >
> > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > >
> > > Brad,
> > >
> > > There are clearly many things I am not understanding about how .NET locates things.... I have a reference in my project to the dotNet DLL in the KMotion/Release directory. It will not allow me to add a reference to the Interop DLL. In this case, it copied the dotNet DLL to the Debug directory, but did not copy the Interop DLL. I manually copied the Interop DLL, and it now works. What am I doing wrong? Why can't I set a reference to the Interop DLL, and how do I get it to copy it anyway?
> > >
> > > Regards,
> > > Ray L.
> > >
> > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > >
> > > > The exception originates in this code, in the Set_G_USER_MCODE_CALLBACK() call:
> > > >
> > > > try
> > > > {
> > > > KM_dotnet_Interop_GCodeInterpreter_New(ref _InstanceHandle);
> > > > Set_G_COMPLETE_CALLBACK();
> > > > Set_G_STATUS_CALLBACK();
> > > > Set_G_USER_CALLBACK();
> > > > Set_G_USER_MCODE_CALLBACK();
> > > > SetStraightTraverseCallback();
> > > > SetStraightFeedCallback();
> > > > SetArcFeedCallback();
> > > > }
> > > >
> > > > Regards,
> > > > Ray L.
> > > >
> > > >
> > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > > >
> > > > > Brad,
> > > > >
> > > > > I've downloaded the compiled DLLs you posted on 1/12, but I'm getting an exception in this block:
> > > > >
> > > > > private void Set_G_USER_MCODE_CALLBACK()
> > > > > {
> > > > > try
> > > > > {
> > > > > InterpreterUserMCodeCallbackRequestedHandler = new KM_GCodeInterpreterUserMcodeCallbackHandler(OnInterpreterUserMcodeCallbackRequested);
> > > > > KM_dotnet_Interop_GCodeInterpreter_Set_G_USER_MCODE_CALLBACK(_InstanceHandle, InterpreterUserMCodeCallbackRequestedHandler);
> > > > > }
> > > > >
> > > > > It's the Interpreter call that's throwing it.
> > > > >
> > > > > Regards,
> > > > > Ray L.
> > > > >
> > > > >
> > > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > > > >
> > > > > > Brad,
> > > > > >
> > > > > > Update them from where? I see an MM update about two weeks ago. Is that it? Is there some fixed location I can go to for updates? It's WAY too easy to miss an announcement here.
> > > > > >
> > > > > > Regards,
> > > > > > Ray L.
> > > > > >
> > > > > > --- In DynoMotion@yahoogroups.com, Brad Murry <bradodarb@> wrote:
> > > > > > >
> > > > > > > Look back a couple weeks here in the forum, I had a discussion on how to use
> > > > > > > it with Kevin.
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > You will have to update your KMotion_dotNet and Interop projects and rebuild
> > > > > > > the DLL's if you only have the base 428 install.
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > -Brad Murry
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > From: DynoMotion@yahoogroups.com [mailto:DynoMotion@yahoogroups.com] On
> > > > > > > Behalf Of himykabibble
> > > > > > > Sent: Sunday, January 22, 2012 4:39 PM
> > > > > > > To: DynoMotion@yahoogroups.com
> > > > > > > Subject: [DynoMotion] How Do M-Codes Get Hooked Into Interpreter?
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > Tom/Brad
> > > > > > >
> > > > > > > How do M-codes get hooked into the interpreter? I don't see anything in the
> > > > > > > APIs that would support that, so I'm sure I must be looking in the wrong
> > > > > > > place.
> > > > > > >
> > > > > > > Regards,
> > > > > > > Ray L.
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>
|
|
Group: DynoMotion |
Message: 3344 |
From: Tom Kerekes |
Date: 1/22/2012 |
Subject: Re: How Do M-Codes Get Hooked Into Interpreter? |
Hi Ray,
I believe so. Search the interpreter for dParams to be sure.
Spindle speed S is treated as MCode Action #10
Regards
TK
Group: DynoMotion |
Message: 3349 |
From: himykabibble |
Date: 1/22/2012 |
Subject: Re: How Do M-Codes Get Hooked Into Interpreter? |
Tom,
OK, found it. It's not clear to me how, in dotNet, I tell it which persist var to use to pass the rpm parameter. It appears it comes from a setup parameter? But the only likely parameter, KMController.Interpreter.SetupParams.SpindleSpeed, is commented as spindle speed override. I assume that's an error, and that parameter actually specifies the persist var for passing rpm?
Regards,
Ray L.
--- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@...> wrote:
>
> Hi Ray,
> Â
> I believe so. Search the interpreter for dParams to be sure.
> Â
> Spindle speed S is treated as MCode Action #10
> Â
> Regards
> TK
>
> From: himykabibble <jagboy@...>
> To: DynoMotion@yahoogroups.com
> Sent: Sunday, January 22, 2012 6:41 PM
> Subject: [DynoMotion] Re: How Do M-Codes Get Hooked Into Interpreter?
>
>
> Â
> Where are the MCode arguments defined? It was easy enough to figure out the bit set ones by trial and error, but what about the others? Are they all in the same order as the KMotionCNC GUI?
>
> Regards,
> Ray L.
>
> --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> >
> > We have MCodes! I've got spindle and coolant controls working! Tomorrow AM, I get to try it on the machine!
> >
> > The axis speeds are waaaaaay slow (rapids are probably no more than about 10% the speed they should be), but positions/counts are correct. I'll double-check my numbers. But it is working!
> >
> > Regards,
> > Ray L.
> >
> > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > >
> > > Brad,
> > >
> > > There are clearly many things I am not understanding about how .NET locates things.... I have a reference in my project to the dotNet DLL in the KMotion/Release directory. It will not allow me to add a reference to the Interop DLL. In this case, it copied the dotNet DLL to the Debug directory, but did not copy the Interop DLL. I manually copied the Interop DLL, and it now works. What am I doing wrong? Why can't I set a reference to the Interop DLL, and how do I get it to copy it anyway?
> > >
> > > Regards,
> > > Ray L.
> > >
> > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > >
> > > > The exception originates in this code, in the Set_G_USER_MCODE_CALLBACK() call:
> > > >
> > > > try
> > > > {
> > > > KM_dotnet_Interop_GCodeInterpreter_New(ref _InstanceHandle);
> > > > Set_G_COMPLETE_CALLBACK();
> > > > Set_G_STATUS_CALLBACK();
> > > > Set_G_USER_CALLBACK();
> > > > Set_G_USER_MCODE_CALLBACK();
> > > > SetStraightTraverseCallback();
> > > > SetStraightFeedCallback();
> > > > SetArcFeedCallback();
> > > > }
> > > >
> > > > Regards,
> > > > Ray L.
> > > >
> > > >
> > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > > >
> > > > > Brad,
> > > > >
> > > > > I've downloaded the compiled DLLs you posted on 1/12, but I'm getting an exception in this block:
> > > > >
> > > > > private void Set_G_USER_MCODE_CALLBACK()
> > > > > {
> > > > > try
> > > > > {
> > > > > InterpreterUserMCodeCallbackRequestedHandler = new KM_GCodeInterpreterUserMcodeCallbackHandler(OnInterpreterUserMcodeCallbackRequested);
> > > > > KM_dotnet_Interop_GCodeInterpreter_Set_G_USER_MCODE_CALLBACK(_InstanceHandle, InterpreterUserMCodeCallbackRequestedHandler);
> > > > > }
> > > > >
> > > > > It's the Interpreter call that's throwing it.
> > > > >
> > > > > Regards,
> > > > > Ray L.
> > > > >
> > > > >
> > > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > > > >
> > > > > > Brad,
> > > > > >
> > > > > > Update them from where? I see an MM update about two weeks ago. Is that it? Is there some fixed location I can go to for updates? It's WAY too easy to miss an announcement here.
> > > > > >
> > > > > > Regards,
> > > > > > Ray L.
> > > > > >
> > > > > > --- In DynoMotion@yahoogroups.com, Brad Murry <bradodarb@> wrote:
> > > > > > >
> > > > > > > Look back a couple weeks here in the forum, I had a discussion on how to use
> > > > > > > it with Kevin.
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > You will have to update your KMotion_dotNet and Interop projects and rebuild
> > > > > > > the DLL's if you only have the base 428 install.
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > -Brad Murry
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > From: DynoMotion@yahoogroups.com [mailto:DynoMotion@yahoogroups.com] On
> > > > > > > Behalf Of himykabibble
> > > > > > > Sent: Sunday, January 22, 2012 4:39 PM
> > > > > > > To: DynoMotion@yahoogroups.com
> > > > > > > Subject: [DynoMotion] How Do M-Codes Get Hooked Into Interpreter?
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > Tom/Brad
> > > > > > >
> > > > > > > How do M-codes get hooked into the interpreter? I don't see anything in the
> > > > > > > APIs that would support that, so I'm sure I must be looking in the wrong
> > > > > > > place.
> > > > > > >
> > > > > > > Regards,
> > > > > > > Ray L.
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>
|
|
Group: DynoMotion |
Message: 3350 |
From: bradodarb |
Date: 1/22/2012 |
Subject: Re: How Do M-Codes Get Hooked Into Interpreter? |
No ray,
It is as described.
To access the persist data, use SetUserData and GetUserData
I'm not sure why you would look for a specificly mapped piece of generic data in the Interpreter. Do you expect everyone to use the same bit of IO for their spindle?
It is in the Controller object as the persist vars are accessible on that level.
-Brad Murry
--- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@...> wrote:
>
> Tom,
>
> OK, found it. It's not clear to me how, in dotNet, I tell it which persist var to use to pass the rpm parameter. It appears it comes from a setup parameter? But the only likely parameter, KMController.Interpreter.SetupParams.SpindleSpeed, is commented as spindle speed override. I assume that's an error, and that parameter actually specifies the persist var for passing rpm?
>
> Regards,
> Ray L.
>
> --- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@> wrote:
> >
> > Hi Ray,
> > Â
> > I believe so. Search the interpreter for dParams to be sure.
> > Â
> > Spindle speed S is treated as MCode Action #10
> > Â
> > Regards
> > TK
> >
> > From: himykabibble <jagboy@>
> > To: DynoMotion@yahoogroups.com
> > Sent: Sunday, January 22, 2012 6:41 PM
> > Subject: [DynoMotion] Re: How Do M-Codes Get Hooked Into Interpreter?
> >
> >
> > Â
> > Where are the MCode arguments defined? It was easy enough to figure out the bit set ones by trial and error, but what about the others? Are they all in the same order as the KMotionCNC GUI?
> >
> > Regards,
> > Ray L.
> >
> > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > >
> > > We have MCodes! I've got spindle and coolant controls working! Tomorrow AM, I get to try it on the machine!
> > >
> > > The axis speeds are waaaaaay slow (rapids are probably no more than about 10% the speed they should be), but positions/counts are correct. I'll double-check my numbers. But it is working!
> > >
> > > Regards,
> > > Ray L.
> > >
> > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > >
> > > > Brad,
> > > >
> > > > There are clearly many things I am not understanding about how .NET locates things.... I have a reference in my project to the dotNet DLL in the KMotion/Release directory. It will not allow me to add a reference to the Interop DLL. In this case, it copied the dotNet DLL to the Debug directory, but did not copy the Interop DLL. I manually copied the Interop DLL, and it now works. What am I doing wrong? Why can't I set a reference to the Interop DLL, and how do I get it to copy it anyway?
> > > >
> > > > Regards,
> > > > Ray L.
> > > >
> > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > > >
> > > > > The exception originates in this code, in the Set_G_USER_MCODE_CALLBACK() call:
> > > > >
> > > > > try
> > > > > {
> > > > > KM_dotnet_Interop_GCodeInterpreter_New(ref _InstanceHandle);
> > > > > Set_G_COMPLETE_CALLBACK();
> > > > > Set_G_STATUS_CALLBACK();
> > > > > Set_G_USER_CALLBACK();
> > > > > Set_G_USER_MCODE_CALLBACK();
> > > > > SetStraightTraverseCallback();
> > > > > SetStraightFeedCallback();
> > > > > SetArcFeedCallback();
> > > > > }
> > > > >
> > > > > Regards,
> > > > > Ray L.
> > > > >
> > > > >
> > > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > > > >
> > > > > > Brad,
> > > > > >
> > > > > > I've downloaded the compiled DLLs you posted on 1/12, but I'm getting an exception in this block:
> > > > > >
> > > > > > private void Set_G_USER_MCODE_CALLBACK()
> > > > > > {
> > > > > > try
> > > > > > {
> > > > > > InterpreterUserMCodeCallbackRequestedHandler = new KM_GCodeInterpreterUserMcodeCallbackHandler(OnInterpreterUserMcodeCallbackRequested);
> > > > > > KM_dotnet_Interop_GCodeInterpreter_Set_G_USER_MCODE_CALLBACK(_InstanceHandle, InterpreterUserMCodeCallbackRequestedHandler);
> > > > > > }
> > > > > >
> > > > > > It's the Interpreter call that's throwing it.
> > > > > >
> > > > > > Regards,
> > > > > > Ray L.
> > > > > >
> > > > > >
> > > > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > > > > >
> > > > > > > Brad,
> > > > > > >
> > > > > > > Update them from where? I see an MM update about two weeks ago. Is that it? Is there some fixed location I can go to for updates? It's WAY too easy to miss an announcement here.
> > > > > > >
> > > > > > > Regards,
> > > > > > > Ray L.
> > > > > > >
> > > > > > > --- In DynoMotion@yahoogroups.com, Brad Murry <bradodarb@> wrote:
> > > > > > > >
> > > > > > > > Look back a couple weeks here in the forum, I had a discussion on how to use
> > > > > > > > it with Kevin.
> > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > > > You will have to update your KMotion_dotNet and Interop projects and rebuild
> > > > > > > > the DLL's if you only have the base 428 install.
> > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > > > -Brad Murry
> > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > > > From: DynoMotion@yahoogroups.com [mailto:DynoMotion@yahoogroups.com] On
> > > > > > > > Behalf Of himykabibble
> > > > > > > > Sent: Sunday, January 22, 2012 4:39 PM
> > > > > > > > To: DynoMotion@yahoogroups.com
> > > > > > > > Subject: [DynoMotion] How Do M-Codes Get Hooked Into Interpreter?
> > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > > > Tom/Brad
> > > > > > > >
> > > > > > > > How do M-codes get hooked into the interpreter? I don't see anything in the
> > > > > > > > APIs that would support that, so I'm sure I must be looking in the wrong
> > > > > > > > place.
> > > > > > > >
> > > > > > > > Regards,
> > > > > > > > Ray L.
> > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>
|
|
Group: DynoMotion |
Message: 3353 |
From: himykabibble |
Date: 1/22/2012 |
Subject: Re: How Do M-Codes Get Hooked Into Interpreter? |
Brad,
I've got simple one and two bit I/Os working, the the S-words are working. But I can't seem to get other M-codes that run programs to work. I tried the following:
KMController.Interpreter.SetMcodeAction(10, MCODE_TYPE.M_Action_Program, 2, 4, 0, 0, 0, @"C:\My KFlop C Programs\KMotionCNC\KMotionCNCSpindlePWM.c");
KMController.Interpreter.SetMcodeAction(11, MCODE_TYPE.M_Action_Program, 4, 4, 0, 0, 0, @"C:\My KFlop C Programs\KMotionCNC\KMotionCNCSpindlePWM.c");
KMController.Interpreter.SetMcodeAction(100, MCODE_TYPE.M_Action_Program, 4, 4, 0, 0, 0, @"C:\My KFlop C Programs\KMotionCNC\KMotionCNCSpindlePWM.c");
The first one works perfectly for S-words. The other two, if I'm understanding correctly, should work for "M11 Pn" and "M100 Pn", but it appears to me neither is actually running the program all, as printfs in the code never show up in the console, while they do for S-words. I'm assuming the first double argument is the thread to use, and the second specifies the first persist var, which will be used for the P parameter, and this indeed works for M10, but not for M11 or M100.
Regards,
Ray L.
--- In DynoMotion@yahoogroups.com, "bradodarb" <bradodarb@...> wrote:
>
> No ray,
>
> It is as described.
>
> To access the persist data, use SetUserData and GetUserData
>
> I'm not sure why you would look for a specificly mapped piece of generic data in the Interpreter. Do you expect everyone to use the same bit of IO for their spindle?
>
> It is in the Controller object as the persist vars are accessible on that level.
>
> -Brad Murry
>
> --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> >
> > Tom,
> >
> > OK, found it. It's not clear to me how, in dotNet, I tell it which persist var to use to pass the rpm parameter. It appears it comes from a setup parameter? But the only likely parameter, KMController.Interpreter.SetupParams.SpindleSpeed, is commented as spindle speed override. I assume that's an error, and that parameter actually specifies the persist var for passing rpm?
> >
> > Regards,
> > Ray L.
> >
> > --- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@> wrote:
> > >
> > > Hi Ray,
> > > Â
> > > I believe so. Search the interpreter for dParams to be sure.
> > > Â
> > > Spindle speed S is treated as MCode Action #10
> > > Â
> > > Regards
> > > TK
> > >
> > > From: himykabibble <jagboy@>
> > > To: DynoMotion@yahoogroups.com
> > > Sent: Sunday, January 22, 2012 6:41 PM
> > > Subject: [DynoMotion] Re: How Do M-Codes Get Hooked Into Interpreter?
> > >
> > >
> > > Â
> > > Where are the MCode arguments defined? It was easy enough to figure out the bit set ones by trial and error, but what about the others? Are they all in the same order as the KMotionCNC GUI?
> > >
> > > Regards,
> > > Ray L.
> > >
> > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > >
> > > > We have MCodes! I've got spindle and coolant controls working! Tomorrow AM, I get to try it on the machine!
> > > >
> > > > The axis speeds are waaaaaay slow (rapids are probably no more than about 10% the speed they should be), but positions/counts are correct. I'll double-check my numbers. But it is working!
> > > >
> > > > Regards,
> > > > Ray L.
> > > >
> > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > > >
> > > > > Brad,
> > > > >
> > > > > There are clearly many things I am not understanding about how .NET locates things.... I have a reference in my project to the dotNet DLL in the KMotion/Release directory. It will not allow me to add a reference to the Interop DLL. In this case, it copied the dotNet DLL to the Debug directory, but did not copy the Interop DLL. I manually copied the Interop DLL, and it now works. What am I doing wrong? Why can't I set a reference to the Interop DLL, and how do I get it to copy it anyway?
> > > > >
> > > > > Regards,
> > > > > Ray L.
> > > > >
> > > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > > > >
> > > > > > The exception originates in this code, in the Set_G_USER_MCODE_CALLBACK() call:
> > > > > >
> > > > > > try
> > > > > > {
> > > > > > KM_dotnet_Interop_GCodeInterpreter_New(ref _InstanceHandle);
> > > > > > Set_G_COMPLETE_CALLBACK();
> > > > > > Set_G_STATUS_CALLBACK();
> > > > > > Set_G_USER_CALLBACK();
> > > > > > Set_G_USER_MCODE_CALLBACK();
> > > > > > SetStraightTraverseCallback();
> > > > > > SetStraightFeedCallback();
> > > > > > SetArcFeedCallback();
> > > > > > }
> > > > > >
> > > > > > Regards,
> > > > > > Ray L.
> > > > > >
> > > > > >
> > > > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > > > > >
> > > > > > > Brad,
> > > > > > >
> > > > > > > I've downloaded the compiled DLLs you posted on 1/12, but I'm getting an exception in this block:
> > > > > > >
> > > > > > > private void Set_G_USER_MCODE_CALLBACK()
> > > > > > > {
> > > > > > > try
> > > > > > > {
> > > > > > > InterpreterUserMCodeCallbackRequestedHandler = new KM_GCodeInterpreterUserMcodeCallbackHandler(OnInterpreterUserMcodeCallbackRequested);
> > > > > > > KM_dotnet_Interop_GCodeInterpreter_Set_G_USER_MCODE_CALLBACK(_InstanceHandle, InterpreterUserMCodeCallbackRequestedHandler);
> > > > > > > }
> > > > > > >
> > > > > > > It's the Interpreter call that's throwing it.
> > > > > > >
> > > > > > > Regards,
> > > > > > > Ray L.
> > > > > > >
> > > > > > >
> > > > > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > > > > > >
> > > > > > > > Brad,
> > > > > > > >
> > > > > > > > Update them from where? I see an MM update about two weeks ago. Is that it? Is there some fixed location I can go to for updates? It's WAY too easy to miss an announcement here.
> > > > > > > >
> > > > > > > > Regards,
> > > > > > > > Ray L.
> > > > > > > >
> > > > > > > > --- In DynoMotion@yahoogroups.com, Brad Murry <bradodarb@> wrote:
> > > > > > > > >
> > > > > > > > > Look back a couple weeks here in the forum, I had a discussion on how to use
> > > > > > > > > it with Kevin.
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > You will have to update your KMotion_dotNet and Interop projects and rebuild
> > > > > > > > > the DLL's if you only have the base 428 install.
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > -Brad Murry
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > From: DynoMotion@yahoogroups.com [mailto:DynoMotion@yahoogroups.com] On
> > > > > > > > > Behalf Of himykabibble
> > > > > > > > > Sent: Sunday, January 22, 2012 4:39 PM
> > > > > > > > > To: DynoMotion@yahoogroups.com
> > > > > > > > > Subject: [DynoMotion] How Do M-Codes Get Hooked Into Interpreter?
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > Tom/Brad
> > > > > > > > >
> > > > > > > > > How do M-codes get hooked into the interpreter? I don't see anything in the
> > > > > > > > > APIs that would support that, so I'm sure I must be looking in the wrong
> > > > > > > > > place.
> > > > > > > > >
> > > > > > > > > Regards,
> > > > > > > > > Ray L.
> > > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>
|
|
Group: DynoMotion |
Message: 3356 |
From: himykabibble |
Date: 1/23/2012 |
Subject: Re: How Do M-Codes Get Hooked Into Interpreter? |
M_Action_Program type M-codes appear to me very broken - The program appears never to be run. I can't get even a simple HelloWorld.c to run.
Regards,
Ray L.
--- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@...> wrote:
>
> Brad,
>
> I've got simple one and two bit I/Os working, the the S-words are working. But I can't seem to get other M-codes that run programs to work. I tried the following:
>
> KMController.Interpreter.SetMcodeAction(10, MCODE_TYPE.M_Action_Program, 2, 4, 0, 0, 0, @"C:\My KFlop C Programs\KMotionCNC\KMotionCNCSpindlePWM.c");
>
> KMController.Interpreter.SetMcodeAction(11, MCODE_TYPE.M_Action_Program, 4, 4, 0, 0, 0, @"C:\My KFlop C Programs\KMotionCNC\KMotionCNCSpindlePWM.c");
>
> KMController.Interpreter.SetMcodeAction(100, MCODE_TYPE.M_Action_Program, 4, 4, 0, 0, 0, @"C:\My KFlop C Programs\KMotionCNC\KMotionCNCSpindlePWM.c");
>
> The first one works perfectly for S-words. The other two, if I'm understanding correctly, should work for "M11 Pn" and "M100 Pn", but it appears to me neither is actually running the program all, as printfs in the code never show up in the console, while they do for S-words. I'm assuming the first double argument is the thread to use, and the second specifies the first persist var, which will be used for the P parameter, and this indeed works for M10, but not for M11 or M100.
>
> Regards,
> Ray L.
>
>
> --- In DynoMotion@yahoogroups.com, "bradodarb" <bradodarb@> wrote:
> >
> > No ray,
> >
> > It is as described.
> >
> > To access the persist data, use SetUserData and GetUserData
> >
> > I'm not sure why you would look for a specificly mapped piece of generic data in the Interpreter. Do you expect everyone to use the same bit of IO for their spindle?
> >
> > It is in the Controller object as the persist vars are accessible on that level.
> >
> > -Brad Murry
> >
> > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > >
> > > Tom,
> > >
> > > OK, found it. It's not clear to me how, in dotNet, I tell it which persist var to use to pass the rpm parameter. It appears it comes from a setup parameter? But the only likely parameter, KMController.Interpreter.SetupParams.SpindleSpeed, is commented as spindle speed override. I assume that's an error, and that parameter actually specifies the persist var for passing rpm?
> > >
> > > Regards,
> > > Ray L.
> > >
> > > --- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@> wrote:
> > > >
> > > > Hi Ray,
> > > > Â
> > > > I believe so. Search the interpreter for dParams to be sure.
> > > > Â
> > > > Spindle speed S is treated as MCode Action #10
> > > > Â
> > > > Regards
> > > > TK
> > > >
> > > > From: himykabibble <jagboy@>
> > > > To: DynoMotion@yahoogroups.com
> > > > Sent: Sunday, January 22, 2012 6:41 PM
> > > > Subject: [DynoMotion] Re: How Do M-Codes Get Hooked Into Interpreter?
> > > >
> > > >
> > > > Â
> > > > Where are the MCode arguments defined? It was easy enough to figure out the bit set ones by trial and error, but what about the others? Are they all in the same order as the KMotionCNC GUI?
> > > >
> > > > Regards,
> > > > Ray L.
> > > >
> > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > > >
> > > > > We have MCodes! I've got spindle and coolant controls working! Tomorrow AM, I get to try it on the machine!
> > > > >
> > > > > The axis speeds are waaaaaay slow (rapids are probably no more than about 10% the speed they should be), but positions/counts are correct. I'll double-check my numbers. But it is working!
> > > > >
> > > > > Regards,
> > > > > Ray L.
> > > > >
> > > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > > > >
> > > > > > Brad,
> > > > > >
> > > > > > There are clearly many things I am not understanding about how .NET locates things.... I have a reference in my project to the dotNet DLL in the KMotion/Release directory. It will not allow me to add a reference to the Interop DLL. In this case, it copied the dotNet DLL to the Debug directory, but did not copy the Interop DLL. I manually copied the Interop DLL, and it now works. What am I doing wrong? Why can't I set a reference to the Interop DLL, and how do I get it to copy it anyway?
> > > > > >
> > > > > > Regards,
> > > > > > Ray L.
> > > > > >
> > > > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > > > > >
> > > > > > > The exception originates in this code, in the Set_G_USER_MCODE_CALLBACK() call:
> > > > > > >
> > > > > > > try
> > > > > > > {
> > > > > > > KM_dotnet_Interop_GCodeInterpreter_New(ref _InstanceHandle);
> > > > > > > Set_G_COMPLETE_CALLBACK();
> > > > > > > Set_G_STATUS_CALLBACK();
> > > > > > > Set_G_USER_CALLBACK();
> > > > > > > Set_G_USER_MCODE_CALLBACK();
> > > > > > > SetStraightTraverseCallback();
> > > > > > > SetStraightFeedCallback();
> > > > > > > SetArcFeedCallback();
> > > > > > > }
> > > > > > >
> > > > > > > Regards,
> > > > > > > Ray L.
> > > > > > >
> > > > > > >
> > > > > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > > > > > >
> > > > > > > > Brad,
> > > > > > > >
> > > > > > > > I've downloaded the compiled DLLs you posted on 1/12, but I'm getting an exception in this block:
> > > > > > > >
> > > > > > > > private void Set_G_USER_MCODE_CALLBACK()
> > > > > > > > {
> > > > > > > > try
> > > > > > > > {
> > > > > > > > InterpreterUserMCodeCallbackRequestedHandler = new KM_GCodeInterpreterUserMcodeCallbackHandler(OnInterpreterUserMcodeCallbackRequested);
> > > > > > > > KM_dotnet_Interop_GCodeInterpreter_Set_G_USER_MCODE_CALLBACK(_InstanceHandle, InterpreterUserMCodeCallbackRequestedHandler);
> > > > > > > > }
> > > > > > > >
> > > > > > > > It's the Interpreter call that's throwing it.
> > > > > > > >
> > > > > > > > Regards,
> > > > > > > > Ray L.
> > > > > > > >
> > > > > > > >
> > > > > > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > > > > > > >
> > > > > > > > > Brad,
> > > > > > > > >
> > > > > > > > > Update them from where? I see an MM update about two weeks ago. Is that it? Is there some fixed location I can go to for updates? It's WAY too easy to miss an announcement here.
> > > > > > > > >
> > > > > > > > > Regards,
> > > > > > > > > Ray L.
> > > > > > > > >
> > > > > > > > > --- In DynoMotion@yahoogroups.com, Brad Murry <bradodarb@> wrote:
> > > > > > > > > >
> > > > > > > > > > Look back a couple weeks here in the forum, I had a discussion on how to use
> > > > > > > > > > it with Kevin.
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > > > You will have to update your KMotion_dotNet and Interop projects and rebuild
> > > > > > > > > > the DLL's if you only have the base 428 install.
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > > > -Brad Murry
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > > > From: DynoMotion@yahoogroups.com [mailto:DynoMotion@yahoogroups.com] On
> > > > > > > > > > Behalf Of himykabibble
> > > > > > > > > > Sent: Sunday, January 22, 2012 4:39 PM
> > > > > > > > > > To: DynoMotion@yahoogroups.com
> > > > > > > > > > Subject: [DynoMotion] How Do M-Codes Get Hooked Into Interpreter?
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > > > Tom/Brad
> > > > > > > > > >
> > > > > > > > > > How do M-codes get hooked into the interpreter? I don't see anything in the
> > > > > > > > > > APIs that would support that, so I'm sure I must be looking in the wrong
> > > > > > > > > > place.
> > > > > > > > > >
> > > > > > > > > > Regards,
> > > > > > > > > > Ray L.
> > > > > > > > > >
> > > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>
|
|
Group: DynoMotion |
Message: 3357 |
From: himykabibble |
Date: 1/23/2012 |
Subject: Re: How Do M-Codes Get Hooked Into Interpreter? |
I take that back. It's not M_Action_Program that's broken. I can't get ANY modes to work on ANY M-codes greater than 10. 3-10 work fine, 11 and up - nada.
Regards,
Ray L.
--- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@...> wrote:
>
> M_Action_Program type M-codes appear to me very broken - The program appears never to be run. I can't get even a simple HelloWorld.c to run.
>
> Regards,
> Ray L.
>
> --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> >
> > Brad,
> >
> > I've got simple one and two bit I/Os working, the the S-words are working. But I can't seem to get other M-codes that run programs to work. I tried the following:
> >
> > KMController.Interpreter.SetMcodeAction(10, MCODE_TYPE.M_Action_Program, 2, 4, 0, 0, 0, @"C:\My KFlop C Programs\KMotionCNC\KMotionCNCSpindlePWM.c");
> >
> > KMController.Interpreter.SetMcodeAction(11, MCODE_TYPE.M_Action_Program, 4, 4, 0, 0, 0, @"C:\My KFlop C Programs\KMotionCNC\KMotionCNCSpindlePWM.c");
> >
> > KMController.Interpreter.SetMcodeAction(100, MCODE_TYPE.M_Action_Program, 4, 4, 0, 0, 0, @"C:\My KFlop C Programs\KMotionCNC\KMotionCNCSpindlePWM.c");
> >
> > The first one works perfectly for S-words. The other two, if I'm understanding correctly, should work for "M11 Pn" and "M100 Pn", but it appears to me neither is actually running the program all, as printfs in the code never show up in the console, while they do for S-words. I'm assuming the first double argument is the thread to use, and the second specifies the first persist var, which will be used for the P parameter, and this indeed works for M10, but not for M11 or M100.
> >
> > Regards,
> > Ray L.
> >
> >
> > --- In DynoMotion@yahoogroups.com, "bradodarb" <bradodarb@> wrote:
> > >
> > > No ray,
> > >
> > > It is as described.
> > >
> > > To access the persist data, use SetUserData and GetUserData
> > >
> > > I'm not sure why you would look for a specificly mapped piece of generic data in the Interpreter. Do you expect everyone to use the same bit of IO for their spindle?
> > >
> > > It is in the Controller object as the persist vars are accessible on that level.
> > >
> > > -Brad Murry
> > >
> > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > >
> > > > Tom,
> > > >
> > > > OK, found it. It's not clear to me how, in dotNet, I tell it which persist var to use to pass the rpm parameter. It appears it comes from a setup parameter? But the only likely parameter, KMController.Interpreter.SetupParams.SpindleSpeed, is commented as spindle speed override. I assume that's an error, and that parameter actually specifies the persist var for passing rpm?
> > > >
> > > > Regards,
> > > > Ray L.
> > > >
> > > > --- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@> wrote:
> > > > >
> > > > > Hi Ray,
> > > > > Â
> > > > > I believe so. Search the interpreter for dParams to be sure.
> > > > > Â
> > > > > Spindle speed S is treated as MCode Action #10
> > > > > Â
> > > > > Regards
> > > > > TK
> > > > >
> > > > > From: himykabibble <jagboy@>
> > > > > To: DynoMotion@yahoogroups.com
> > > > > Sent: Sunday, January 22, 2012 6:41 PM
> > > > > Subject: [DynoMotion] Re: How Do M-Codes Get Hooked Into Interpreter?
> > > > >
> > > > >
> > > > > Â
> > > > > Where are the MCode arguments defined? It was easy enough to figure out the bit set ones by trial and error, but what about the others? Are they all in the same order as the KMotionCNC GUI?
> > > > >
> > > > > Regards,
> > > > > Ray L.
> > > > >
> > > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > > > >
> > > > > > We have MCodes! I've got spindle and coolant controls working! Tomorrow AM, I get to try it on the machine!
> > > > > >
> > > > > > The axis speeds are waaaaaay slow (rapids are probably no more than about 10% the speed they should be), but positions/counts are correct. I'll double-check my numbers. But it is working!
> > > > > >
> > > > > > Regards,
> > > > > > Ray L.
> > > > > >
> > > > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > > > > >
> > > > > > > Brad,
> > > > > > >
> > > > > > > There are clearly many things I am not understanding about how .NET locates things.... I have a reference in my project to the dotNet DLL in the KMotion/Release directory. It will not allow me to add a reference to the Interop DLL. In this case, it copied the dotNet DLL to the Debug directory, but did not copy the Interop DLL. I manually copied the Interop DLL, and it now works. What am I doing wrong? Why can't I set a reference to the Interop DLL, and how do I get it to copy it anyway?
> > > > > > >
> > > > > > > Regards,
> > > > > > > Ray L.
> > > > > > >
> > > > > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > > > > > >
> > > > > > > > The exception originates in this code, in the Set_G_USER_MCODE_CALLBACK() call:
> > > > > > > >
> > > > > > > > try
> > > > > > > > {
> > > > > > > > KM_dotnet_Interop_GCodeInterpreter_New(ref _InstanceHandle);
> > > > > > > > Set_G_COMPLETE_CALLBACK();
> > > > > > > > Set_G_STATUS_CALLBACK();
> > > > > > > > Set_G_USER_CALLBACK();
> > > > > > > > Set_G_USER_MCODE_CALLBACK();
> > > > > > > > SetStraightTraverseCallback();
> > > > > > > > SetStraightFeedCallback();
> > > > > > > > SetArcFeedCallback();
> > > > > > > > }
> > > > > > > >
> > > > > > > > Regards,
> > > > > > > > Ray L.
> > > > > > > >
> > > > > > > >
> > > > > > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > > > > > > >
> > > > > > > > > Brad,
> > > > > > > > >
> > > > > > > > > I've downloaded the compiled DLLs you posted on 1/12, but I'm getting an exception in this block:
> > > > > > > > >
> > > > > > > > > private void Set_G_USER_MCODE_CALLBACK()
> > > > > > > > > {
> > > > > > > > > try
> > > > > > > > > {
> > > > > > > > > InterpreterUserMCodeCallbackRequestedHandler = new KM_GCodeInterpreterUserMcodeCallbackHandler(OnInterpreterUserMcodeCallbackRequested);
> > > > > > > > > KM_dotnet_Interop_GCodeInterpreter_Set_G_USER_MCODE_CALLBACK(_InstanceHandle, InterpreterUserMCodeCallbackRequestedHandler);
> > > > > > > > > }
> > > > > > > > >
> > > > > > > > > It's the Interpreter call that's throwing it.
> > > > > > > > >
> > > > > > > > > Regards,
> > > > > > > > > Ray L.
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > > > > > > > >
> > > > > > > > > > Brad,
> > > > > > > > > >
> > > > > > > > > > Update them from where? I see an MM update about two weeks ago. Is that it? Is there some fixed location I can go to for updates? It's WAY too easy to miss an announcement here.
> > > > > > > > > >
> > > > > > > > > > Regards,
> > > > > > > > > > Ray L.
> > > > > > > > > >
> > > > > > > > > > --- In DynoMotion@yahoogroups.com, Brad Murry <bradodarb@> wrote:
> > > > > > > > > > >
> > > > > > > > > > > Look back a couple weeks here in the forum, I had a discussion on how to use
> > > > > > > > > > > it with Kevin.
> > > > > > > > > > >
> > > > > > > > > > >
> > > > > > > > > > >
> > > > > > > > > > > You will have to update your KMotion_dotNet and Interop projects and rebuild
> > > > > > > > > > > the DLL's if you only have the base 428 install.
> > > > > > > > > > >
> > > > > > > > > > >
> > > > > > > > > > >
> > > > > > > > > > > -Brad Murry
> > > > > > > > > > >
> > > > > > > > > > >
> > > > > > > > > > >
> > > > > > > > > > > From: DynoMotion@yahoogroups.com [mailto:DynoMotion@yahoogroups.com] On
> > > > > > > > > > > Behalf Of himykabibble
> > > > > > > > > > > Sent: Sunday, January 22, 2012 4:39 PM
> > > > > > > > > > > To: DynoMotion@yahoogroups.com
> > > > > > > > > > > Subject: [DynoMotion] How Do M-Codes Get Hooked Into Interpreter?
> > > > > > > > > > >
> > > > > > > > > > >
> > > > > > > > > > >
> > > > > > > > > > >
> > > > > > > > > > >
> > > > > > > > > > > Tom/Brad
> > > > > > > > > > >
> > > > > > > > > > > How do M-codes get hooked into the interpreter? I don't see anything in the
> > > > > > > > > > > APIs that would support that, so I'm sure I must be looking in the wrong
> > > > > > > > > > > place.
> > > > > > > > > > >
> > > > > > > > > > > Regards,
> > > > > > > > > > > Ray L.
> > > > > > > > > > >
> > > > > > > > > >
> > > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>
|
|
Group: DynoMotion |
Message: 3358 |
From: Tom Kerekes |
Date: 1/23/2012 |
Subject: Re: How Do M-Codes Get Hooked Into Interpreter? |
Hi Ray,
I think you are mis-interpreting the first parameter as the MCode number rather than the Action Index. The Low M_Codes, S, 10 User Buttons, M100-119 MCodes, and are all packed into a table about 50 entries long. See the defines below.
Also See the SimpleGCode.cpp code for an example.
Regards
TK
#define MAX_MCODE_ACTIONS_M1 11 // actually only 2-10 are used
#define MAX_MCODE_ACTIONS_BUTTONS 10
#define MAX_MCODE_ACTIONS_M100 20
#define MAX_MCODE_ACTIONS (MAX_MCODE_ACTIONS_M1+MAX_MCODE_ACTIONS_M100+MAX_MCODE_ACTIONS_BUTTONS)
#define MCODE_ACTIONS_M100_OFFSET (MAX_MCODE_ACTIONS_M1+MAX_MCODE_ACTIONS_BUTTONS)
Group: DynoMotion |
Message: 3360 |
From: himykabibble |
Date: 1/23/2012 |
Subject: Re: How Do M-Codes Get Hooked Into Interpreter? |
Brad,
Much better! Thanks! I'm off to try my new app on the machine!
Regards,
Ray L.
--- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@...> wrote:
>
> Hi Ray,
> Â
> I think you are mis-interpreting the first parameter as the MCode number rather than the Action Index. The Low M_Codes, S, 10 User Buttons, M100-119 MCodes, and are all packed into a table about 50 entries long. See the defines below.Â
> Â
> Also See the SimpleGCode.cpp code for an example.
> Â
> Regards
> TKÂ
> Â
> Â
> Â #defineMAX_MCODE_ACTIONS_M1 11 // actually only 2-10 are used#defineMAX_MCODE_ACTIONS_BUTTONS 10#defineMAX_MCODE_ACTIONS_M100 20#defineMAX_MCODE_ACTIONS (MAX_MCODE_ACTIONS_M1+MAX_MCODE_ACTIONS_M100+MAX_MCODE_ACTIONS_BUTTONS)
> #defineMCODE_ACTIONS_M100_OFFSET (MAX_MCODE_ACTIONS_M1+MAX_MCODE_ACTIONS_BUTTONS)
> Â
> Â
>
> From: himykabibble <jagboy@...>
> To: DynoMotion@yahoogroups.com
> Sent: Monday, January 23, 2012 8:12 AM
> Subject: [DynoMotion] Re: How Do M-Codes Get Hooked Into Interpreter?
>
>
> Â
> M_Action_Program type M-codes appear to me very broken - The program appears never to be run. I can't get even a simple HelloWorld.c to run.
>
> Regards,
> Ray L.
>
> --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> >
> > Brad,
> >
> > I've got simple one and two bit I/Os working, the the S-words are working. But I can't seem to get other M-codes that run programs to work. I tried the following:
> >
> > KMController.Interpreter.SetMcodeAction(10, MCODE_TYPE.M_Action_Program, 2, 4, 0, 0, 0, @"C:\My KFlop C Programs\KMotionCNC\KMotionCNCSpindlePWM.c");
> >
> > KMController.Interpreter.SetMcodeAction(11, MCODE_TYPE.M_Action_Program, 4, 4, 0, 0, 0, @"C:\My KFlop C Programs\KMotionCNC\KMotionCNCSpindlePWM.c");
> >
> > KMController.Interpreter.SetMcodeAction(100, MCODE_TYPE.M_Action_Program, 4, 4, 0, 0, 0, @"C:\My KFlop C Programs\KMotionCNC\KMotionCNCSpindlePWM.c");
> >
> > The first one works perfectly for S-words. The other two, if I'm understanding correctly, should work for "M11 Pn" and "M100 Pn", but it appears to me neither is actually running the program all, as printfs in the code never show up in the console, while they do for S-words. I'm assuming the first double argument is the thread to use, and the second specifies the first persist var, which will be used for the P parameter, and this indeed works for M10, but not for M11 or M100.
> >
> > Regards,
> > Ray L.
> >
> >
> > --- In DynoMotion@yahoogroups.com, "bradodarb" <bradodarb@> wrote:
> > >
> > > No ray,
> > >
> > > It is as described.
> > >
> > > To access the persist data, use SetUserData and GetUserData
> > >
> > > I'm not sure why you would look for a specificly mapped piece of generic data in the Interpreter. Do you expect everyone to use the same bit of IO for their spindle?
> > >
> > > It is in the Controller object as the persist vars are accessible on that level.
> > >
> > > -Brad Murry
> > >
> > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > >
> > > > Tom,
> > > >
> > > > OK, found it. It's not clear to me how, in dotNet, I tell it which persist var to use to pass the rpm parameter. It appears it comes from a setup parameter? But the only likely parameter, KMController.Interpreter.SetupParams.SpindleSpeed, is commented as spindle speed override. I assume that's an error, and that parameter actually specifies the persist var for passing rpm?
> > > >
> > > > Regards,
> > > > Ray L.
> > > >
> > > > --- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@> wrote:
> > > > >
> > > > > Hi Ray,
> > > > > ÃÂ
> > > > > I believe so.ÃÂ Search the interpreter for dParams to be sure.
> > > > > ÃÂ
> > > > > Spindle speed S is treated as MCode Action #10
> > > > > ÃÂ
> > > > > Regards
> > > > > TK
> > > > >
> > > > > From: himykabibble <jagboy@>
> > > > > To: DynoMotion@yahoogroups.com
> > > > > Sent: Sunday, January 22, 2012 6:41 PM
> > > > > Subject: [DynoMotion] Re: How Do M-Codes Get Hooked Into Interpreter?
> > > > >
> > > > >
> > > > > ÃÂ
> > > > > Where are the MCode arguments defined? It was easy enough to figure out the bit set ones by trial and error, but what about the others? Are they all in the same order as the KMotionCNC GUI?
> > > > >
> > > > > Regards,
> > > > > Ray L.
> > > > >
> > > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > > > >
> > > > > > We have MCodes! I've got spindle and coolant controls working! Tomorrow AM, I get to try it on the machine!
> > > > > >
> > > > > > The axis speeds are waaaaaay slow (rapids are probably no more than about 10% the speed they should be), but positions/counts are correct. I'll double-check my numbers. But it is working!
> > > > > >
> > > > > > Regards,
> > > > > > Ray L.
> > > > > >
> > > > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > > > > >
> > > > > > > Brad,
> > > > > > >
> > > > > > > There are clearly many things I am not understanding about how .NET locates things.... I have a reference in my project to the dotNet DLL in the KMotion/Release directory. It will not allow me to add a reference to the Interop DLL. In this case, it copied the dotNet DLL to the Debug directory, but did not copy the Interop DLL. I manually copied the Interop DLL, and it now works. What am I doing wrong? Why can't I set a reference to the Interop DLL, and how do I get it to copy it anyway?
> > > > > > >
> > > > > > > Regards,
> > > > > > > Ray L.
> > > > > > >
> > > > > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > > > > > >
> > > > > > > > The exception originates in this code, in the Set_G_USER_MCODE_CALLBACK() call:
> > > > > > > >
> > > > > > > > try
> > > > > > > > {
> > > > > > > > KM_dotnet_Interop_GCodeInterpreter_New(ref _InstanceHandle);
> > > > > > > > Set_G_COMPLETE_CALLBACK();
> > > > > > > > Set_G_STATUS_CALLBACK();
> > > > > > > > Set_G_USER_CALLBACK();
> > > > > > > > Set_G_USER_MCODE_CALLBACK();
> > > > > > > > SetStraightTraverseCallback();
> > > > > > > > SetStraightFeedCallback();
> > > > > > > > SetArcFeedCallback();
> > > > > > > > }
> > > > > > > >
> > > > > > > > Regards,
> > > > > > > > Ray L.
> > > > > > > >
> > > > > > > >
> > > > > > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > > > > > > >
> > > > > > > > > Brad,
> > > > > > > > >
> > > > > > > > > I've downloaded the compiled DLLs you posted on 1/12, but I'm getting an exception in this block:
> > > > > > > > >
> > > > > > > > > private void Set_G_USER_MCODE_CALLBACK()
> > > > > > > > > {
> > > > > > > > > try
> > > > > > > > > {
> > > > > > > > > InterpreterUserMCodeCallbackRequestedHandler = new KM_GCodeInterpreterUserMcodeCallbackHandler(OnInterpreterUserMcodeCallbackRequested);
> > > > > > > > > KM_dotnet_Interop_GCodeInterpreter_Set_G_USER_MCODE_CALLBACK(_InstanceHandle, InterpreterUserMCodeCallbackRequestedHandler);
> > > > > > > > > }
> > > > > > > > >
> > > > > > > > > It's the Interpreter call that's throwing it.
> > > > > > > > >
> > > > > > > > > Regards,
> > > > > > > > > Ray L.
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote:
> > > > > > > > > >
> > > > > > > > > > Brad,
> > > > > > > > > >
> > > > > > > > > > Update them from where? I see an MM update about two weeks ago. Is that it? Is there some fixed location I can go to for updates? It's WAY too easy to miss an announcement here.
> > > > > > > > > >
> > > > > > > > > > Regards,
> > > > > > > > > > Ray L.
> > > > > > > > > >
> > > > > > > > > > --- In DynoMotion@yahoogroups.com, Brad Murry <bradodarb@> wrote:
> > > > > > > > > > >
> > > > > > > > > > > Look back a couple weeks here in the forum, I had a discussion on how to use
> > > > > > > > > > > it with Kevin.
> > > > > > > > > > >
> > > > > > > > > > >
> > > > > > > > > > >
> > > > > > > > > > > You will have to update your KMotion_dotNet and Interop projects and rebuild
> > > > > > > > > > > the DLL's if you only have the base 428 install.
> > > > > > > > > > >
> > > > > > > > > > >
> > > > > > > > > > >
> > > > > > > > > > > -Brad Murry
> > > > > > > > > > >
> > > > > > > > > > >
> > > > > > > > > > >
> > > > > > > > > > > From: DynoMotion@yahoogroups.com [mailto:DynoMotion@yahoogroups.com] On
> > > > > > > > > > > Behalf Of himykabibble
> > > > > > > > > > > Sent: Sunday, January 22, 2012 4:39 PM
> > > > > > > > > > > To: DynoMotion@yahoogroups.com
> > > > > > > > > > > Subject: [DynoMotion] How Do M-Codes Get Hooked Into Interpreter?
> > > > > > > > > > >
> > > > > > > > > > >
> > > > > > > > > > >
> > > > > > > > > > >
> > > > > > > > > > >
> > > > > > > > > > > Tom/Brad
> > > > > > > > > > >
> > > > > > > > > > > How do M-codes get hooked into the interpreter? I don't see anything in the
> > > > > > > > > > > APIs that would support that, so I'm sure I must be looking in the wrong
> > > > > > > > > > > place.
> > > > > > > > > > >
> > > > > > > > > > > Regards,
> > > > > > > > > > > Ray L.
> > > > > > > > > > >
> > > > > > > > > >
> > > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>
|
|
Group: DynoMotion |
Message: 3530 |
From: Brad Murry |
Date: 1/28/2012 |
Subject: Re: How Do M-Codes Get Hooked Into Interpreter? |
Hello Ray, Tom want everything to reference and run in the KMotion4xx\KMotion\Release folder. You can either have your program live there, set the PATH environmental variable, add the installed KMotion_dotNet.dll to the GAC or load the assembly at runtime using Assembly.LoadFrom(uri) The interop DLL is a C++ library and not a managed DLL. This means you cannot directly reference it in your projects, nor do you need to. Its various methods are used by the KMotion_dotNet.dll via pinvoke. -Brad Murry From: DynoMotion@yahoogroups.com [mailto:DynoMotion@yahoogroups.com] On Behalf Of himykabibble Sent: Sunday, January 22, 2012 7:07 PM To: DynoMotion@yahoogroups.com Subject: [DynoMotion] Re: How Do M-Codes Get Hooked Into Interpreter? Brad,
There are clearly many things I am not understanding about how .NET locates things.... I have a reference in my project to the dotNet DLL in the KMotion/Release directory. It will not allow me to add a reference to the Interop DLL. In this case, it copied the dotNet DLL to the Debug directory, but did not copy the Interop DLL. I manually copied the Interop DLL, and it now works. What am I doing wrong? Why can't I set a reference to the Interop DLL, and how do I get it to copy it anyway?
Regards, Ray L.
--- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@...> wrote: > > The exception originates in this code, in the Set_G_USER_MCODE_CALLBACK() call: > > try > { > KM_dotnet_Interop_GCodeInterpreter_New(ref _InstanceHandle); > Set_G_COMPLETE_CALLBACK(); > Set_G_STATUS_CALLBACK(); > Set_G_USER_CALLBACK(); > Set_G_USER_MCODE_CALLBACK(); > SetStraightTraverseCallback(); > SetStraightFeedCallback(); > SetArcFeedCallback(); > } > > Regards, > Ray L. > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote: > > > > Brad, > > > > I've downloaded the compiled DLLs you posted on 1/12, but I'm getting an exception in this block: > > > > private void Set_G_USER_MCODE_CALLBACK() > > { > > try > > { > > InterpreterUserMCodeCallbackRequestedHandler = new KM_GCodeInterpreterUserMcodeCallbackHandler(OnInterpreterUserMcodeCallbackRequested); > > KM_dotnet_Interop_GCodeInterpreter_Set_G_USER_MCODE_CALLBACK(_InstanceHandle, InterpreterUserMCodeCallbackRequestedHandler); > > } > > > > It's the Interpreter call that's throwing it. > > > > Regards, > > Ray L. > > > > > > --- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@> wrote: > > > > > > Brad, > > > > > > Update them from where? I see an MM update about two weeks ago. Is that it? Is there some fixed location I can go to for updates? It's WAY too easy to miss an announcement here. > > > > > > Regards, > > > Ray L. > > > > > > --- In DynoMotion@yahoogroups.com, Brad Murry <bradodarb@> wrote: > > > > > > > > Look back a couple weeks here in the forum, I had a discussion on how to use > > > > it with Kevin. > > > > > > > > > > > > > > > > You will have to update your KMotion_dotNet and Interop projects and rebuild > > > > the DLL's if you only have the base 428 install. > > > > > > > > > > > > > > > > -Brad Murry > > > > > > > > > > > > > > > > From: DynoMotion@yahoogroups.com [mailto:DynoMotion@yahoogroups.com] On > > > > Behalf Of himykabibble > > > > Sent: Sunday, January 22, 2012 4:39 PM > > > > To: DynoMotion@yahoogroups.com > > > > Subject: [DynoMotion] How Do M-Codes Get Hooked Into Interpreter? > > > > > > > > > > > > > > > > > > > > > > > > Tom/Brad > > > > > > > > How do M-codes get hooked into the interpreter? I don't see anything in the > > > > APIs that would support that, so I'm sure I must be looking in the wrong > > > > place. > > > > > > > > Regards, > > > > Ray L. > > > > > > > > > >
|
|
Group: DynoMotion |
Message: 3545 |
From: himykabibble |
Date: 1/28/2012 |
Subject: Re: How Do M-Codes Get Hooked Into Interpreter? |
Brad,
I am pointing everything to the DLLs in the Release folder, and the app EXE is put in the Release folder. But at the time I was having that problem, Debug builds were still pointing to the Debug folder.
Regards,
Ray L.
--- In DynoMotion@yahoogroups.com, Brad Murry <bradodarb@...> wrote:
>
> Hello Ray,
>
>
>
> Tom want everything to reference and run in the KMotion4xx\KMotion\Release
> folder.
>
>
>
>
>
> You can either have your program live there, set the PATH environmental
> variable, add the installed KMotion_dotNet.dll to the GAC or load the
> assembly at runtime using Assembly.LoadFrom(uri)
>
>
>
>
>
> The interop DLL is a C++ library and not a managed DLL. This means you
> cannot directly reference it in your projects, nor do you need to. Its
> various methods are used by the KMotion_dotNet.dll via pinvoke.
>
>
>
> -Brad Murry
>
>
>
>
>
>
>
> From: DynoMotion@yahoogroups.com [mailto:DynoMotion@yahoogroups.com] On
> Behalf Of himykabibble
> Sent: Sunday, January 22, 2012 7:07 PM
> To: DynoMotion@yahoogroups.com
> Subject: [DynoMotion] Re: How Do M-Codes Get Hooked Into Interpreter?
>
>
>
>
>
> Brad,
>
> There are clearly many things I am not understanding about how .NET locates
> things.... I have a reference in my project to the dotNet DLL in the
> KMotion/Release directory. It will not allow me to add a reference to the
> Interop DLL. In this case, it copied the dotNet DLL to the Debug directory,
> but did not copy the Interop DLL. I manually copied the Interop DLL, and it
> now works. What am I doing wrong? Why can't I set a reference to the Interop
> DLL, and how do I get it to copy it anyway?
>
> Regards,
> Ray L.
>
> --- In DynoMotion@yahoogroups.com <mailto:DynoMotion%40yahoogroups.com> ,
> "himykabibble" <jagboy@> wrote:
> >
> > The exception originates in this code, in the Set_G_USER_MCODE_CALLBACK()
> call:
> >
> > try
> > {
> > KM_dotnet_Interop_GCodeInterpreter_New(ref _InstanceHandle);
> > Set_G_COMPLETE_CALLBACK();
> > Set_G_STATUS_CALLBACK();
> > Set_G_USER_CALLBACK();
> > Set_G_USER_MCODE_CALLBACK();
> > SetStraightTraverseCallback();
> > SetStraightFeedCallback();
> > SetArcFeedCallback();
> > }
> >
> > Regards,
> > Ray L.
> >
> >
> > --- In DynoMotion@yahoogroups.com <mailto:DynoMotion%40yahoogroups.com> ,
> "himykabibble" <jagboy@> wrote:
> > >
> > > Brad,
> > >
> > > I've downloaded the compiled DLLs you posted on 1/12, but I'm getting an
> exception in this block:
> > >
> > > private void Set_G_USER_MCODE_CALLBACK()
> > > {
> > > try
> > > {
> > > InterpreterUserMCodeCallbackRequestedHandler = new
> KM_GCodeInterpreterUserMcodeCallbackHandler(OnInterpreterUserMcodeCallbackRe
> quested);
> > >
> KM_dotnet_Interop_GCodeInterpreter_Set_G_USER_MCODE_CALLBACK(_InstanceHandle
> , InterpreterUserMCodeCallbackRequestedHandler);
> > > }
> > >
> > > It's the Interpreter call that's throwing it.
> > >
> > > Regards,
> > > Ray L.
> > >
> > >
> > > --- In DynoMotion@yahoogroups.com <mailto:DynoMotion%40yahoogroups.com>
> , "himykabibble" <jagboy@> wrote:
> > > >
> > > > Brad,
> > > >
> > > > Update them from where? I see an MM update about two weeks ago. Is
> that it? Is there some fixed location I can go to for updates? It's WAY too
> easy to miss an announcement here.
> > > >
> > > > Regards,
> > > > Ray L.
> > > >
> > > > --- In DynoMotion@yahoogroups.com
> <mailto:DynoMotion%40yahoogroups.com> , Brad Murry <bradodarb@> wrote:
> > > > >
> > > > > Look back a couple weeks here in the forum, I had a discussion on
> how to use
> > > > > it with Kevin.
> > > > >
> > > > >
> > > > >
> > > > > You will have to update your KMotion_dotNet and Interop projects and
> rebuild
> > > > > the DLL's if you only have the base 428 install.
> > > > >
> > > > >
> > > > >
> > > > > -Brad Murry
> > > > >
> > > > >
> > > > >
> > > > > From: DynoMotion@yahoogroups.com
> <mailto:DynoMotion%40yahoogroups.com> [mailto:DynoMotion@yahoogroups.com
> <mailto:DynoMotion%40yahoogroups.com> ] On
> > > > > Behalf Of himykabibble
> > > > > Sent: Sunday, January 22, 2012 4:39 PM
> > > > > To: DynoMotion@yahoogroups.com <mailto:DynoMotion%40yahoogroups.com>
>
> > > > > Subject: [DynoMotion] How Do M-Codes Get Hooked Into Interpreter?
> > > > >
> > > > >
> > > > >
> > > > >
> > > > >
> > > > > Tom/Brad
> > > > >
> > > > > How do M-codes get hooked into the interpreter? I don't see anything
> in the
> > > > > APIs that would support that, so I'm sure I must be looking in the
> wrong
> > > > > place.
> > > > >
> > > > > Regards,
> > > > > Ray L.
> > > > >
> > > >
> > >
> >
>
|
|
| | | | | | | | | |